<?php if( ! defined('BASEPATH')) exit('No direct script access allowed'); ?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE>Untitled Page</TITLE>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<STYLE type=text/css>
{
FONT-SIZE
:
 
12
px


}
.gridView {
	BORDER-RIGHT: #bad6ec 1px;
	BORDER-TOP: #bad6ec 1px;
	BORDER-LEFT: #bad6ec 1px;
	COLOR: #566984;
	BORDER-BOTTOM: #bad6ec 1px;
	FONT-FAMILY: Courier New
}

.gridViewHeader {
	BORDER-RIGHT: #bad6ec 1px solid;
	BORDER-TOP: #bad6ec 1px solid;
	BACKGROUND-IMAGE: url(<?php echo base_url(); ?> images /bg_th.gif);
	BORDER-LEFT: #bad6ec 1px solid;
	LINE-HEIGHT: 27px;
	BORDER-BOTTOM: #bad6ec 1px solid
}

.gridViewItem {
	BORDER-RIGHT: #bad6ec 1px solid;
	BORDER-TOP: #bad6ec 1px solid;
	BORDER-LEFT: #bad6ec 1px solid;
	LINE-HEIGHT: 32px;
	BORDER-BOTTOM: #bad6ec 1px solid;
	TEXT-ALIGN: center
}

.cmdField {
	BORDER-RIGHT: 0px;
	BORDER-TOP: 0px;
	BACKGROUND-IMAGE: url(<?php echo base_url(); ?> images
	/bg_rectbtn.png);
	OVERFLOW: hidden;
	BORDER-LEFT: 0px;
	WIDTH: 67px;
	COLOR: #364c6d;
	LINE-HEIGHT: 27px;
	BORDER-BOTTOM: 0px;
	BACKGROUND-REPEAT: repeat-x;
	HEIGHT: 27px;
	BACKGROUND-COLOR: transparent;
	TEXT-DECORATION: none
}

.buttonBlue {
	BORDER-RIGHT: 0px;
	BORDER-TOP: 0px;
	BACKGROUND-IMAGE: url(<?php echo base_url(); ?> images
	/bg_button_blue.gif);
	BORDER-LEFT: 0px;
	WIDTH: 78px;
	COLOR: white;
	BORDER-BOTTOM: 0px;
	BACKGROUND-REPEAT: no-repeat;
	HEIGHT: 21px
}
</STYLE>
<META content="MSHTML 6.00.2900.5848" name=GENERATOR>
</HEAD>
<BODY 
style="BACKGROUND-POSITION-Y: -120px; BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/bg.gif); BACKGROUND-REPEAT: repeat-x">
	<form action=empSerCount_doAdd method="post">
		<DIV>
			<TABLE height="100%" cellSpacing=0 cellPadding=0 width="100%" border=0>
				<TBODY>
					<TR 
  style="BACKGROUND-IMAGE: url(<?php echo base_url(); ?>/images/bg_header.gif); BACKGROUND-REPEAT: repeat-x" 
  height=47>
						<TD width=10><SPAN 
      style="FLOAT: left; BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_hl.gif); WIDTH: 15px; BACKGROUND-REPEAT: no-repeat; HEIGHT: 47px"></SPAN></TD>
						<TD><SPAN 
      style="FLOAT: left; BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_hl2.gif); WIDTH: 15px; BACKGROUND-REPEAT: no-repeat; HEIGHT: 47px"></SPAN><SPAN 
      style="PADDING-RIGHT: 10px; PADDING-LEFT: 10px; FLOAT: left; BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_hb.gif); PADDING-BOTTOM: 10px; COLOR: white; PADDING-TOP: 10px; BACKGROUND-REPEAT: repeat-x; HEIGHT: 47px; TEXT-ALIGN: center; 0px: ">add servers record </SPAN> <SPAN style="FLOAT: left; BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_hr.gif); WIDTH: 60px; BACKGROUND-REPEAT: no-repeat; HEIGHT: 47px"></SPAN></TD>
						<TD 
    style="BACKGROUND-POSITION: 50% bottom; BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_rc.gif)" 
    width=10></TD>
					</TR>
					<TR>
						<TD style="BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_ls.gif)">&nbsp;</TD>
						<TD style="PADDING-RIGHT: 10px; PADDING-LEFT: 10px; PADDING-BOTTOM: 10px; COLOR: #566984; PADDING-TOP: 10px; BACKGROUND-COLOR: white" vAlign=top align=middle>
							<DIV>
								<TABLE class=gridView id=ctl00_ContentPlaceHolder2_GridView1 style="WIDTH: 60%; BORDER-COLLAPSE: collapse" cellSpacing=0 rules=all border=1>
									<TBODY>
										<tr>
											<input type="hidden" id="employeid" name="employeid" />
											<input type="hidden" id="serverid" name="serverid" />
										</tr>
										<tr>
											<td class=gridViewItem>employe</td>
											<td class=gridViewItem><select name="select_employeid" id="select_employeid" onchange="setEmployeid(this.options[this.selectedIndex].value)">
													<option selected='selected'>=select employe=</option>
													<?php foreach($query->result() as $row ): ?>
													<option class=gridViewItem value='<?=$row->employeid?>'>
													<?=$row->employena?>
													</option>
													<?php endforeach ?>
											</select>
											</td>
										</tr>
										<TR>
											<TD class=gridViewItem>server</TD>
											<td class=gridViewItem><select name="select_employeid" id="select_employeid" onchange="setServerid(this.options[this.selectedIndex].value)">
													<option selected='selected'>=select server=</option>
													<?php foreach($serverinfo->result() as $row ): ?>
													<option class=gridViewItem value='<?=$row->serverid?>'>
													<?=$row->serverna?>
													</option>
													<?php endforeach ?>
											</select>
											</td>
											<input type="hidden" id="sercount" name="sercount" value='0' />
										</TR>

									</TBODY>
								</TABLE>
								<A class=cmdField href="javascript:doSubmit();">submit</A> <a class=cmdField href="<?php echo base_url(); ?>/admin/empSerCountInfo">return</a>
						
						</TD>
						<TD style="BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_rs.gif)"></TD>
					</TR>
					<TR 
  style="BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_fs.gif); BACKGROUND-REPEAT: repeat-x" 
  height=10>
						<TD style="BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_lf.gif)"></TD>
						<TD style="BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_fs.gif)"></TD>
						<TD 
style="BACKGROUND-IMAGE: url(<?php echo base_url(); ?>images/main_rf.gif)"></TD>
					</TR>
				</TBODY>
			</TABLE>
		</DIV>
	</form>
</BODY>
<script type="text/javascript">
function setEmployeid(a){
		 
		document.getElementById("employeid").value=a;//赋值
	}
function setServerid(a){
		 
		document.getElementById("serverid").value=a;//赋值
	}
function doSubmit()
{
	var employeid=document.getElementById("employeid").value;
	var serverid=document.getElementById("serverid").value;
	var reg1 = /^[0-9]+$/;
	var em = reg1.test(employeid);
	var pa = reg1.test(serverid);
	if(employeid!="" && pa && serverid!="" &&  em){
		document.forms[0].submit();
	}else{
		document.write("please add staff first，to be sure that there is some ones can be selected，and some one is selected，and be sure what you input is a number!");
		//document.write("<a class=cmdField href='<?php echo base_url(); ?>/admin/empSerCountInfo'>return</a>");
		}
	
}
</script>
</HTML>

